package com.xinzhi.savingpot.userinfo.controller;



import com.xinzhi.savingpot.userinfo.service.impl.AuthenticationImpl;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;


@RestController
@RequestMapping("Authentication")
@Api("初级实名认证")
public class AuthenticationController {
    @Autowired
    AuthenticationImpl authentication;

    @GetMapping("Certification")
    @ApiOperation("实名认证")
    public String Certification(@RequestParam("realName") String realName, @RequestParam("nationalldentifiCation") String nationalldentifiCation,@RequestParam("token") String token){
        /*String Itoken = token.getHeader("token");
        Claims claims = JwtUtil.checkJWT(Itoken);
        String user = claims.getAudience();*/

        return authentication.addCertification(realName,nationalldentifiCation,token);
    }
}
